Growth in color management has resulted in an increase in software packages that are used to generate International Color Consortium (ICC) profiles. ICC profiles describe color attributes of a particular device or viewing requirement by defining mappings between a device color space and device independent color space. Typically, profiles created by a standard organization, e.g., International Organization for Standardization (ISO) are selected as printer input profiles when printing cyan, magenta, yellow, black (CMYK) print jobs.
Color management performs a multi-dimensional interpolation of an input color within a high-dimensional Look Up Table (LUT). Such LUT interpolations are often processor intensive. Thus, a common technique is to cache converted colors for later use. Implementation of an open-addressed hash table (or cache) is typically the most efficient means of color caching. However when the number of stored entries in the table becomes excessively large, hash collisions tend to increase. The increase in hash collisions result in the total time spent searching the cache (e.g., for both stored and un-stored) colors becoming comparable to, or even exceeding, the time it would take to simply perform a LUT interpolation.
Reinitializing the hash table can mitigate this problem. However, determining the optimal time to reinitialize the hash table is a challenge. Moreover, individual entries cannot be removed from the hash table once being added. Thus, the entire table must be erased and reinitialized (or reset). As a result, reinitializing should only be performed when necessary. Current mechanisms reinitialize the hash table when a predetermined fixed percentage of the table size is used up. This percentage directly determines an average number of hash collisions that occur when a color is looked up, but does not directly indicate whether beneficial to reinitialize the hash table and start over.
Accordingly, an improved mechanism to optimize hash table reinitialization is desired.